package com.demos.webcommon.事务;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.jdbc.core.JdbcTemplate;
import org.springframework.stereotype.Repository;

@Repository("TransactionDao2")
public class dao2 {
    @Autowired
    private JdbcTemplate template;

    public int add(String name){
        return template.update("insert into table2(name) values(?)", name);
    }
}
